package selef.xiafan.util.result;

import lombok.Data;

/**
 * @author xiafan
 * @version 1.0
 * @date 2021/7/12 10:10
 */
@Data
public class PageResult<T> {
    //返回总条数
    private Long total = 0L;
    //返回分页数据
    private Object result;

    private int code;

    private String message;

    public PageResult() {
    }

    public PageResult(Long total, Object result) {
        this.total = total;
        this.result = result;
    }

    public PageResult(int resultCode, String message, Object data) {
        this.code = resultCode;
        this.message = message;
        this.result = data;
    }
}
